<extend name="Public:Base" />
<block name="title">
    <title>美住 - 客栈申请</title>
</block>
<block name="extendHead">
    <link rel="stylesheet" href="__PUBLIC__/src/meizhu/HotelApply/index.css" />
    <link rel="stylesheet" href="__PUBLIC__/jslib/bootstrap-datepicker/css/bootstrap-datepicker.min.css" />
</block>
<block name="document">
    <div id="doc" data-side-menu-id="sideMenuMainAccount" data-side-menu-toggle-id="collapseHotelToggle">
        <div id="doc-header">
            <include file="Public:Include_navbar" />
        </div>
        <div id="doc-center">
            <div class="container">
                <div class="col-xs-3-15">
                    <include file="Public:Include_sideMenu" />
                </div>
                <div class="col-xs-12-15">
                    <nav class="navbar navbar-default navbar-custom-fitin">
                        <div class="container-fluid">
                            <p class="navbar-text custom-navber-text">试用账号列表</p>
                        </div>
                    </nav>
                    <nav class="navbar navbar-default navbar-custom-fitin nav-padding">
                        <div class="container-fluid">
                            <div class="collapse navbar-collapse">

                            </div>
                        </div>
                    </nav> 
                    <div class="well well-custom-has-navbar">
                        <div class="well-custom-body">
                            <div class="table-responsive">
                                <table class="table table-bordered table-hover" id="questionTalbe">
                                    <thead>
                                        <tr>
                                            <th>客栈管理员</th>
                                            <th>手机号</th>
                                            <th class="col-xs-3-15">到期时间(双击修改)</th>
											<th>状态</th>
                                            <th class="col-xs-2-15">操作</th>
                                        </tr>
                                    </thead>
                                    <tbody>
                                    <foreach name="shiyongAccounts" item="vo">
                                        <tr>
                                            <td>{$vo.name}</td>
                                            <td>{$vo.mobile}</td>
                                            <td class="shiyong-day" data-value="{$vo.id}" date="{$vo.endtime}">{$vo.endtime}</td>
											<td>
											<switch name="vo.status">
												<case value="0"><span class="text-muted">已失效</span></case>
												<case value="1"><span class="text-primary">试用中</span></case>
												<case value="2"><span class="text-danger">已申请</span></case>
												<case value="3"><span class="text-success">已通过</span></case>
											</switch>
											</td>
											<td>
												<if condition="$vo.status eq 2">
                                                <button class="btn btn-default btn-sm shiyongPass" data-value="{$vo.id}" data-toggle="modal" data-target="#passModel">开通</button>
											    </if>
												<!-- <button class="btn btn-danger btn-sm confuse"  data-toggle="modal" data-target="#statusModel">关停</button> -->
                                            </td>
                                        </tr>
                                    </foreach>
                                    <tr class="padtopx"><td colspan="5">{$page}</td></tr>
                                    </tbody>
                                </table>
                            </div>
                        </div>
                    </div>
                </div>
            </div>
        </div>

        <div id="doc-footer">
            <include file="Public:Include_footer" />
        </div>
    </div>
	 <!-- 开通模态框 -->
    <div class="modal fade" id="passModel">
        <div class="modal-dialog">
            <div class="modal-content">
                <div class="modal-header">
                    <button type="button" id="requestCannel" class="close" data-dismiss="modal" aria-label="Close"><span aria-hidden="true">&times;</span>
                    </button>
                    <h4 class="modal-title">确定状态</h4>
                </div>
                <div class="modal-body">
                    <h3>您确定要<span class="text-success">将你选择的客栈更改为开通？</span></h3>
                </div>
                <div class="modal-footer">
                    <button type="button" class="btn btn-success" data-value="" id="requestPass">确定</button>
                </div>
            </div>
        </div>
    </div>
</block>

<block name="extendFootJs">
    <script type="text/javascript" src="__PUBLIC__/src/meizhu/common.js"></script>    
    <script type="text/javascript" src="__PUBLIC__/uclbrt/js/jquery-plugin/tooltip.js"></script>
    <script type="text/javascript" src="__PUBLIC__/src/meizhu/Account/shiyong.js?123123123"></script>
    <script type="text/javascript" src="/Public/jslib/bootstrap-datepicker/js/bootstrap-datepicker.min.js"></script>
</block>

